<script type="text/javascript" src="<? print APP_NAME ?>lib/jquery/jquery.js"></script>
<script type="text/javascript">
function forForgetPassword(){
	var email	=	$("#email").val();
	if(email == ''){
		alert("Enter your email first !");
	}
	else{
		if(checkEmail(email)){
			$("#result").html("Processing ...");
			$.get(
			"<? print url("Default","DoForForgetPassword") ?>",
			{Email:$("#email").val()},
			function(data){
				alert(data);
				$("#result").html("");
			});
		}
	}
}
function checkEmail(email){
 	var pattern = /^([a-zA-Z0-9._-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/;
 	flag = pattern.test(email);
 	if(!flag){
  		alert(email + "  is not a correct email !");
  		return false;
 	}
 	return (true);
}
</script>

<div id="left" class ="corner">
<h2><span>Client Login</span></h2>
<form name="memberLogin" action="<? print url("Default","DoLogin") ?>" method="post">
<label>Enter Your Email</label>
<input type="text" name="Email" class="txtBox" id="email"/>
<label>Enter Your Password</label>
<input type="password" name="Password" class="txtBox" />
<br class="spacer" />
<input type="submit" name="login" value="Login" style="font-weight:bold;margin-top:5px;"/>
<a href="#" onclick="forForgetPassword();return false;">Forget your password</a><br class="spacer" />

<a href="<? print url("Default","PractitionerLogin") ?>">Practitioner Login</a>
</form>
<div id="result" style="float:left;padding-left:15px;"></div>
</div>